<html>
<head>
     <title>Help: corrcoef</title>
</head>
<body>
     <center><table><tbody>
          <tr>
             <td style="border: 1px solid rgb(170, 170, 170); padding: 5px; background-color: #fff;">
                  <h4>corrcoef</h4>Correlation coefficients.
                  <br><small>Last modified: 25-Sep-2009 16:28:37</small>

          </tr>
          <tr>
             <td style="border: 0px solid rgb(170, 170, 170); padding: 5px; background-color: #fff;">
                  <a href="http://guillaumemaze.googlecode.com/svn/trunk/matlab/codes/overwrite/corrcoef.m">Download here</a>
             </td>
          </tr>
          <tr>
             <td style="border: 1px solid rgb(170, 170, 170); padding: 5px; background-color: #ddd; font-size:12px;">
                  <br>% CORRCOEF Correlation coefficients.<br>%   R=CORRCOEF(X) calculates a matrix R of correlation coefficients for<br>%   an array X, in which each row is an observation and each column is a<br>%   variable.<br>%<br>%   R=CORRCOEF(X,Y), where X and Y are column vectors, is the same as<br>%   R=CORRCOEF([X Y]).<br>%   <br>%   If C is the covariance matrix, C = COV(X), then CORRCOEF(X) is<br>%   the matrix whose (i,j)'th element is<br>%<br>%          C(i,j)/SQRT(C(i,i)*C(j,j)).<br>%<br>%   [R,P]=CORRCOEF(...) also returns P, a matrix of p-values for testing<br>%   the hypothesis of no correlation.  Each p-value is the probability<br>%   of getting a correlation as large as the observed value by random<br>%   chance, when the true correlation is zero.  If P(i,j) is small, say<br>%   less than 0.05, then the correlation R(i,j) is significant.<br>%<br>%   [R,P,RLO,RUP]=CORRCOEF(...) also returns matrices RLO and RUP, of<br>%   the same size as R, containing lower and upper bounds for a 95%<br>%   confidence interval for each coefficient.<br>%<br>%   [...]=CORRCOEF(...,'PARAM1',VAL1,'PARAM2',VAL2,...) specifies additional<br>%   parameters and their values.  Valid parameters are the following:<br>% <br>%       Parameter  Value<br>%       'alpha'    A number between 0 and 1 to specify a confidence<br>%                  level of 100*(1-ALPHA)%.  Default is 0.05 for 95%<br>%                  confidence intervals.<br>%       'rows'     Either 'all' (default) to use all rows, 'complete' to<br>%                  use rows with no NaN values, or 'pairwise' to compute<br>%                  R(i,j) using rows with no NaN values in column i or j.<br>%<br>%   The p-value is computed by transforming the correlation to create a t<br>%   statistic having N-2 degrees of freedom, where N is the number of rows<br>%   of X.  The confidence bounds are based on an asymptotic normal<br>%   distribution of 0.5*log((1+R)/(1-R)), with an approximate variance equal<br>%   to 1/(N-3).  These bounds are accurate for large samples when X has a<br>%   multivariate normal distribution.  The 'pairwise' option can produce<br>%   an R matrix that is not positive definite.<br>%<br>%   Example:  Generate random data having correlation between column 4<br>%             and the other columns.<br>%       x = randn(30,4);       % uncorrelated data<br>%       x(:,4) = sum(x,2);     % introduce correlation<br>%       [r,p] = corrcoef(x)    % compute sample correlation and p-values<br>%       [i,j] = find(p<0.05);  % find significant correlations<br>%       [i,j]                  % display their (row,col) indices<br>%<br>%   See also COV, STD.
             </td>
          </tr>
          <tr>
             <td style="border: 1px solid rgb(170, 170, 170); padding: 5px; background-color: #fff; font-size:12px;">
                  Last update: 2011 March 04, 17:46<br>
                  Created by Guillaume Maze<br>
                  More informations at: <a href="http://codes.guillaumemaze.org/matlab">codes.guillaumemaze.org/matlab</a><br>
             </td>
          </tr>
     </tbody></table></center>
</body>
</html>
